﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace MusicAcademy
{
    public partial class frmMain : Form
    {
        public frmMain()
        {
            InitializeComponent();
        }

        private void اساتیدToolStripMenuItem_Click(object sender, EventArgs e)
        {

        }

        private void کلاسهاToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmClass FrmClass = new frmClass();
            FrmClass.ShowDialog();
        }

        private void روزهایتعطیلToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmHoliday Holiday = new frmHoliday();
            Holiday.ShowDialog();
        }

        private void سازهاToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmTool Tool = new frmTool();
            Tool.ShowDialog();
        }

        private void هنرجویانToolStripMenuItem_Click(object sender, EventArgs e)
        {
            
        }

        private void ثبتنامToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmRegisterTerm reg = new frmRegisterTerm();
            reg.ShowDialog();
        }

        private void دورههاToolStripMenuItem1_Click(object sender, EventArgs e)
        {
            frmTerm term = new frmTerm();
            term.ShowDialog();
        }

        private void frmMain_Load(object sender, EventArgs e)
        {
            
        }

        private void صورتحسابToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmTransactions t = new frmTransactions();
            t.ShowDialog();
        }

        private void پرداختشهریهToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmNewPayment p = new frmNewPayment();
            p.PaymentType = 1;//Credit
            p.PersonType = 2;//Student
            p.Text = "پرداخت شهریه";
            p.lblName.Text = "هنرجو :";
            p.ShowDialog();
        }

        private void پرداختحقالتدریساستادToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmNewPayment p = new frmNewPayment();
            p.PaymentType = 2;//Debit
            p.PersonType = 1;//Teacher
            p.Text = "پرداخت حق التدریس استاد";
            p.lblName.Text = "استاد :";
            p.ShowDialog();
        }

        private void تغییرکلاسهاToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmSessions s = new frmSessions();
            s.ShowDialog();
        }

        private void حضوروغیابToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmSessions s = new frmSessions();
            s.fromDate.Text = Globals.Get10CharDate();
            s.toDate.Text = Globals.Get10CharDate();
            s.ShowDialog();
        }

        private void دفترچهتلفنToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmPhoneBook p = new frmPhoneBook();
            p.ShowDialog();
        }

        private void برنامههفتگیToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmTeacherFreeTime t = new frmTeacherFreeTime();
            t.ShowDialog();
        }

        private void آرشیومدارکToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmPersonFiles p = new frmPersonFiles();
            p.ShowDialog();
        }

        private void آرشیومدارکToolStripMenuItem1_Click(object sender, EventArgs e)
        {
            frmPersonFiles p = new frmPersonFiles();
            p.ShowDialog();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            frmTeachers t = new frmTeachers();
            t.ShowDialog();
        }

        private void button2_Click(object sender, EventArgs e)
        {
            frmStudents s = new frmStudents();
            s.ShowDialog();
        }

        private void button3_Click(object sender, EventArgs e)
        {
            frmRegisterTerm r = new frmRegisterTerm();
            r.ShowDialog();
        }

        private void button4_Click(object sender, EventArgs e)
        {
            frmSessions s = new frmSessions();
            s.fromDate.Text = Globals.Get10CharDate();
            s.toDate.Text = Globals.Get10CharDate();
            s.ShowDialog();
        }

        private void button5_Click(object sender, EventArgs e)
        {
            frmTerm t = new frmTerm();
            t.ShowDialog();
        }

        private void button6_Click(object sender, EventArgs e)
        {
            frmPhoneBook p = new frmPhoneBook();
            p.ShowDialog();
        }

        private void frmMain_FormClosing(object sender, FormClosingEventArgs e)
        {
            Application.Exit();
        }

        private void لیستاساتیدToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmTeachers Teachers = new frmTeachers();
            Teachers.ShowDialog();
        }

        private void لیستهنرجویانToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmStudents Students = new frmStudents();
            Students.ShowDialog();
        }

        private void گزارشاتToolStripMenuItem1_Click(object sender, EventArgs e)
        {
            frmReports r = new frmReports();
            r.ShowDialog();
        }
    }
}
